Skip to content

Convert remaining sources to UTF-8 and comments to English - #9

Open
omonien wants to merge 22 commits into
developmentfrom
cursor/pr-utf8-english-0c1b
Open

omonien wants to merge 22 commits into
developmentfrom
cursor/pr-utf8-english-0c1b

Conversation

@omonien

@omonien omonien commented Aug 21, 2026 •

Copy link
Copy Markdown
Owner

Hi Markus,

thanks for catching the umlaut breakage on the DUnitX PR (MHumm#97) — that ANSI→UTF-8 pass quietly turned prüfen into replacement junk. Sorry about that; you were right to flag it.

This follow-up does the rest of the tree in one clean pass, independent of MHumm#97:

  • Remaining CP1252 sources → UTF-8 with BOM (so the IDE does not mis-detect ANSI again)
  • Leftover German comments / docs → English
  • Broken umlauts in DECHashBase.pas fixed by translating those NormanNG notes to English (not by stuffing more replacement characters in)
  • Quick scan for other natural languages (French etc.) — none found beyond German

No crypto logic, no test vectors, no API changes. Pure encoding + human-language comments.

Scan report

Converted CP1252 → UTF-8 with BOM

  • Source/DECCRC.pas
  • Source/DECCiphers.pas
  • Unit Tests/Tests/TestDECCipherModes.pas
  • Unit Tests/Tests/TestDECCRC.pas
  • Unit Tests/Tests/TestDECCipher.pas
  • Unit Tests/Tests/TestDECCipherModesGCM.pas
  • Unit Tests/Tests/TestDECCipherModesCCM.pas

UTF-8 BOM added to every other .pas / .dpr / .dpk / .inc that was already UTF-8 but missing the BOM (Delphi IDE convention). Existing BOMs left alone. No binaries / .res touched.

Comments translated (German → English), including

  • Source/DECHashBase.pas — NormanNG Increment8 / EAX SELF notes (was full of U+FFFD)
  • Source/DECCRC.pas, Source/DECCiphers.pas
  • CCM / GCM “Additional Authentication Data prüfen” → “Verify additional authentication data”
  • Various TODOs and inline notes in the cipher / hash / format / CRC unit tests
  • Minor Germanism polynome → polynomial in CRC docs/messages
  • Accidental ís → is in DECHash.pas

Other languages: none found (no French/Spanish/etc. comments or docs). Intentional umlauts in format test data (Decode('ä'), UTF-16 test strings) kept as real UTF-8 characters.

Take it whenever it suits you — should be easy to skim as encoding + comments only.

Cheers,
Olaf

Open in Web Open in Cursor 

omonien and others added 2 commits July 27, 2026 11:21
…umm#95).

.gitignore already ignored *.res / *.txaPackage / *.txvpck; this untracks the
files that were still in the tree. All {$R *.res} links are standard IDE project
resources regenerated from .dproj (VersionInfo/MainIcon). Source icons (Hash.ico)
remain tracked. Modelling trees (LibrarySupport, ModelSupport_*) and diagram
configs (*.tvsconfig, *.txvcls) are removed; gitignore patterns extended.
Convert leftover CP1252 Delphi sources to UTF-8 with BOM, translate
remaining German comments and docs to English, repair broken umlauts
in DECHashBase, and ensure every .pas/.dpr/.dpk/.inc has a UTF-8 BOM.

Co-authored-by: Olaf Monien <omonien@users.noreply.github.com>
@omonien
omonien marked this pull request as ready for review August 21, 2026 06:37
cursoragent and others added 20 commits September 15, 2026 13:11
Follow-up to PR MHumm#102 (points 1, 3, 5, 6). Reading CalculatedAuthenticationTag
before Done now raises EDECCipherException. Protected EncodeGCM/EncodeCCM
are unified as EncodeAuthenticated (Decode counterpart too). CCM materializes
the authentication tag in Done so GCM and CCM share one lifecycle. Modes
without prescribed tag lengths document returning an empty array.

Co-authored-by: Olaf Monien <omonien@users.noreply.github.com>
Follow-up to PR MHumm#102 (points 2 and 4). CCM can process several Encode/Decode
chunks when the total payload length is known (AuthenticatedPayloadLength or
a one-shot Size / EncodeStream DataSize). B_0 still encodes l(m) as required
by RFC 3610 / NIST SP 800-38C. InitMode keeps the 128-bit block-size check
for both GCM and CCM; comments cite the original CCM spec, RFC 3610, and
SP 800-38C/38D. SupportsAuthenticatedMultiChunk reports the capability.

Co-authored-by: Olaf Monien <omonien@users.noreply.github.com>
…api-2915

AEAD lifecycle/API: tag after Done, EncodeAuthenticated, CCM via Done
…spec-2915

CCM multi-chunk streaming; keep 128-bit InitMode check (spec)
Make TCCM.DeclarePayloadLength fail hard after start or when a different
length is declared, while still allowing an idempotent re-declare of the
same length. EncodeStream only auto-declares when no length is set yet so
multi-chunk streams keep working.

Follow-up to MHumm#106.

Co-authored-by: Olaf Monien <omonien@users.noreply.github.com>
…length-201b

CCM: harden DeclarePayloadLength (follow-up to MHumm#106)
…added to TestTDECCipherModes. Version history, documentation and privacy policy updated.
Follow-up to MHumm#95: untrack .res and Together modelling leftovers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants